const express = require("express")
const cors = require('cors')
const app = express()
const port = 1256
const { xmlStr, newBpmn } = require('./const')

// 跨域处理
app.use(cors())

app.get('/getXml', (req, res) => {
  res.send(xmlStr)
})

app.get('/newBpmn', (req, res) => {
  res.send(newBpmn)
})

app.listen(port, () => {
  console.log(`listen port ${port}`)
})